/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 殇
 * Date: 2025-05-20
 * Time: 10:31
 */
//将数字元素均*2
public class code1 {
    public static void transform(int[] array){
        int n=array.length;
        for(int i=0;i<n;i++){
            array[i]*=2;
        }
    }
    public static void main(String[] args) {
        int[] array={1,2,3,4,5};
        transform(array);
        for(int x:array){
            System.out.print(x+" ");
        }
    }
}
